<?php 
$categories = $mvc->getObject(CategoryService::CATEGORY);
$subcategories = $mvc->getObject(SubCategoryService::SUBCATEGORY);
$regions = $mvc->getObject(RegionService::REGIONS);
?>
<div class="wrapMain">
	<div class="greyBox">
		<div class="itemFace"></div>
		<div class="itemHand"></div>
		<!-- box on -->
		<div class="viewBox viewBoxB">
			<div class="cT"><em class="cL"></em><em class="cR"></em></div>
			<div class="cL">
				<div class="cR">
					<div class="bodyBox">
						<h2>Jetzt Angebote einholen</h2>
						<div class="unitSearch">
							<form action="/new-order.html" method="post">
								<p>
									<select name="category_id" class="gCategory">
		<?php					if (isset($categories) && $categories!=NULL){ 
									foreach($categories as $key=>$category){ ?>
										<option value="<?php echo $category[CategoryService::ID] ?>"><?php echo $category[CategoryService::CAT_NAME] ?></option>
		<?php 						} 
								} ?>
									</select>
									<label>_i18n{Category}?</label>
								</p>
								<p>
									<select name="subcategory_id" class="gSubCategory">
		<?php					if (isset($subcategories) && $subcategories!=NULL){ 
									foreach($subcategories as $key=>$subcategory){ ?>
										<option value="<?php echo $subcategory[SubCategoryService::ID] ?>"><?php echo $subcategory[SubCategoryService::SUBCAT_NAME] ?></option>
		<?php 						}
								} ?>
									</select>
									<label>_i18n{SubCategory}?</label>
								</p>
								<p class="itemBtn">
									<button type="submit"><span><strong>_i18n{Make a free offer}<!-- Angebot kostenlos holen! --></strong></span></button>
								</p>
							</form>
						</div>
					</div>
				</div>
			</div>
			<div class="cB"><em class="cL"></em><em class="cR"></em></div>
		</div>
		<!-- box off -->
		<!-- list on -->
		<div class="viewDlist">
			<h3>Die Vorteile von angebotholen.at</h3>
			<ul>
				<li>Kostenlos, Provisionsfrei</li>
				<li>Nie wieder zuviel bezahlen</li>
				<li>Bequem vergleichen</li>
				<li>Absolut verbindlich</li>
				<li>Empfehlungen</li>
				<li>Qualitätsarbeit</li>
			</ul>
		</div>
		<!-- list off -->
		<!-- box on -->
		<div class="viewBox viewBoxB">
			<div class="cT"><em class="cL"></em><em class="cR"></em></div>
			<div class="cL">
				<div class="cR">
					<div class="bodyBox">
						<h2>So finden Sie das beste Angebot!</h2>
						<div class="unitStep">
							<ol>
								<li>
									<span><img src="images/nbrFind01.gif" alt="Ihren Auftrag kostenlos eintragen" /></span>
									<span>Ihren Auftrag kostenlos eintragen</span>
								</li>
								<li>
									<span><img src="images/nbrFind02.gif" alt="Angebote vergleichen" /></span>
									<span>Angebote vergleichen</span>
								</li>
								<li>
									<span><img src="images/nbrFind03.gif" alt="Auftrag vergeben" /></span>
									<span>Auftrag vergeben</span>
								</li>
							</ol>
						</div>
					</div>
				</div>
			</div>
			<div class="cB"><em class="cL"></em><em class="cR"></em></div>
		</div>
		<!-- box off -->
		<!-- small box on -->
		<div class="viewBox viewBoxC">
			<div class="cT"><em class="cL"></em><em class="cR"></em></div>
			<div class="cL">
				<div class="cR">
					<div class="bodyBox">
						<h3>So geht's Video</h3>
						<div class="unitVideo">
							<div class="itemVideo"><img src="images/cnt/contentImg09.gif" alt="Video" /></div>
						</div>
					</div>
				</div>
			</div>
			<div class="cB"><em class="cL"></em><em class="cR"></em></div>
		</div>
		<!-- small box off -->
		<!-- two lists on -->
		<div class="viewTList">
			<?php	if (isset($categories) && $categories!=NULL){ 
				$count = count($categories);
				$middle = $count/2;
			?>
			<ul>
			<?php foreach($categories as $key=>$category){
				if ($middle==$key) { ?></ul><ul><?php } ?>
				<li><a href="/view-orders.html?category_id=<?php echo $category[CategoryService::ID] ?>" title="<?php echo $category[CategoryService::CAT_NAME] ?>"><?php echo $category[CategoryService::CAT_NAME] ?></a></li>
				<?php } ?> 
			</ul>
			<?php	} ?>
		</div>
		<!-- two lists off -->
		<!-- small box on -->
		<div class="viewBox viewBoxC">
			<div class="cT"><em class="cL"></em><em class="cR"></em></div>
			<div class="cL">
				<div class="cR">
					<div class="bodyBox">
						<h3>_i18n{Yellow Pages}</h3>
						<div class="unitYellow">
							<form action="/companies.html" method="get">
								<p>
									<label>_i18n{Industry}?</label>
									<select name="cat_id">
		<?php					if (isset($categories) && $categories!=NULL){ 
									foreach($categories as $key=>$category){ ?>
										<option value="<?php echo $category[CategoryService::ID] ?>"><?php echo $category[CategoryService::CAT_NAME] ?></option>
		<?php 						} 
								} ?>
									</select>
								</p>
								<p>
									<label>_i18n{Region}?</label>
									<select name="region">
												<option value="all">all</option>
										<?php			if (isset($regions) && $regions!=NULL){ 
					foreach($regions as $key=>$region){ ?>
												<option <?php echo isset($_GET['region'])&&$region[RegionService::ID]==$_GET['region'] ? "selected='selected'" : NULL ; ?> value="<?php echo $region[RegionService::ID] ?>"><?php echo $region[RegionService::REGION_NAME] ?></option>
										<?php 				} 
				} ?>
									</select>
								</p>
								<p class="itemBtn">
									<button type="submit"><span><strong>_i18n{Search}</strong></span></button>
								</p>
							</form>
						</div>
					</div>
				</div>
			</div>
			<div class="cB"><em class="cL"></em><em class="cR"></em></div>
		</div>
		<!-- small box off -->
		<!-- fix gradient on -->
		<div class="lineHide"></div>
		<!-- fix gradient off -->
	</div>
</div>